import 'package:dio/dio.dart';
import 'dart:async';
import 'dart:io';
// import '../config/service_url.dart';

// 获取首页数据
Future getHomePageContent()async{
  try {
   Response response;
   Dio dio = new Dio();
  response = await dio.get("http://dianshan.free.idcfengye.com/goods/main");
   if(response.statusCode==200){
     return response.toString();
   } else {
     throw Exception('后端接口出现异常');
   }
  } catch (e) {
    return print('error:====>${e}');
  }
}
